notebook: fix arrow states
authorMatthias Clasen <mclasen@redhat.com>
Thu, 11 Feb 2016 11:47:28 +0000 (06:47 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Thu, 11 Feb 2016 11:47:28 +0000 (06:47 -0500)
Some code was confusing 0 with ARROW_NONE, causing us to not properly
update the state of the arrow gadgets.

gtk/gtknotebook.c

index 26de2bc86aa2ce3e952958556eb3dd89e2eceafb..6f9fafce5608608ad44de4f6d173940720cc765c 100644 (file)
@@ -1273,7 +1273,7 @@ gtk_notebook_init (GtkNotebook *notebook)
   priv->tab_pos = GTK_POS_TOP;
   priv->scrollable = FALSE;
   priv->in_child = ARROW_NONE;
-  priv->click_child = 0;
+  priv->click_child = ARROW_NONE;
   priv->need_timer = 0;
   priv->child_has_focus = FALSE;
   priv->focus_out = FALSE;
@@ -2533,9 +2533,9 @@ gtk_notebook_show_arrows (GtkNotebook *notebook)
 }
 
 static void
-gtk_notebook_get_arrow_rect (GtkNotebook     *notebook,
-                             GdkRectangle    *rectangle,
-                             GtkNotebookArrow arrow)
+gtk_notebook_get_arrow_rect (GtkNotebook      *notebook,
+                             GdkRectangle     *rectangle,
+                             GtkNotebookArrow  arrow)
 {
   GtkNotebookPrivate *priv = notebook->priv;
 
@@ -2840,7 +2840,7 @@ stop_scrolling (GtkNotebook *notebook)
       priv->timer = 0;
       priv->need_timer = FALSE;
     }
-  priv->click_child = 0;
+  priv->click_child = ARROW_NONE;
   priv->pressed_button = 0;
   gtk_notebook_redraw_arrows (notebook);
 }